/*
 * @Author: czy
 * @Date: 2021-04-26 07:44:06
 * @LastEditTime: 2021-07-13 21:03:05
 */
#ifndef __CMD_H_
#define __CMD_H_

#define MAX_ARGC 3
#define COMMAND_SIZE 30
#define BUFFER 100
#define HISTORY_SIZE 30
#define PROMPT "\033[32mczy > \033[0m"

typedef struct
{
    char *head;
    char *tail;
    char *current;
    int output_str_len;
} instruction;

void startShell(void);
void addNewCmd(char *name, char *help_content, int (*func)(int argc, char *argv[]));
void submitCmd(char *str);
void register_command(void);
void *cmd_pointer(void);

#endif